package com.zealfi.wk.api.service;

import com.zealfi.wk.api.pojo.User;
import org.springframework.web.bind.annotation.*;

/**
 * Created by kuan at 2018-04-24 上午 9:44
 */
@RequestMapping("refactor")
public interface HelloService {

    @RequestMapping("hello")
    String hello();

    @RequestMapping(value = "hello3", method = RequestMethod.GET)
    String hello(@RequestParam("name") String name);

    @RequestMapping(value = "hello4", method = RequestMethod.GET)
    User hello(@RequestHeader("name") String name, @RequestHeader("age") Integer age);

    @RequestMapping(value = "hello4", method = RequestMethod.POST)
    String hello(@RequestBody User user);

    @RequestMapping(value = "hello5/{userId}", method = RequestMethod.GET)
    String hello5(@RequestParam(name = "userId") Long userId);
}
